package com.ky.gp.app.service;


import com.ky.common.param.ProblemAdd;
import com.ky.common.vo.R;
import com.ky.gp.app.config.OpenFeignConfig;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient(value = "gp-circle-server", configuration = OpenFeignConfig.class)
public interface ProblemFeign {

    @RequestMapping("/circle/problem/selectProblemList")
    R selectProblemList();

    @RequestMapping("/circle/problem/selectProblemById/{id}")
    R selectProblemById(@PathVariable("id") Integer id);

    @RequestMapping("/circle/problem/addProblem")
    R addProblem(@RequestBody ProblemAdd problemAdd);

    @RequestMapping("/circle/problem/addFollowers/{id}")
    R addFollowers(@PathVariable("id") int id);

    @RequestMapping("/circle/problem/commentsCount/{id}/commentsCount")
    R commentCount(@PathVariable("id") int id);

    @RequestMapping("/circle/problem/follow/{id}/follow")
    R selectFollow(@PathVariable("id") int id);
}
